# Maintainer: Celeste <cielesti@protonmail.com>
maintainer="Celeste <cielesti@protonmail.com>"
pkgname=emacs-powerline
pkgver=2.4_git20221110
_gitrev=c35c35bdf5ce2d992882c1f06f0f078058870d4a
pkgrel=0
_pkgreal=powerline
pkgdesc="Library for customizing the mode-line"
url="https://github.com/milkypostman/powerline"
arch="noarch"
license="GPL-3.0-or-later"
depends="cmd:emacs"
makedepends="emacs-nox"
source="https://github.com/milkypostman/powerline/archive/$_gitrev/emacs-powerline-$_gitrev.tar.gz"
builddir="$srcdir/$_pkgreal-$_gitrev"
options="!check" # no tests provided

build() {
	emacs -batch -q -no-site-file -L . \
		-f batch-byte-compile \
		./*.el
}

package() {
	install -Dvm644 ./*.el ./*.elc \
		-t "$pkgdir"/usr/share/emacs/site-lisp/$_pkgreal/

	cd "$pkgdir"/usr/share/emacs/site-lisp/$_pkgreal
	emacs -batch -q -no-site-file \
		-eval "(loaddefs-generate \".\" \"$_pkgreal-loaddefs.el\")"
}

sha512sums="
be0eedd1b79e37b80f0520706af11b36d0775aced51f08239d240fc19c1c54124bc736009cb2eb1332b9a9a064221885dcaebfac5595211afe9939409256d92b  emacs-powerline-c35c35bdf5ce2d992882c1f06f0f078058870d4a.tar.gz
"
